// Provide `global` for libraries (sockjs-client / stompjs) that expect a Node-like global
if (typeof window !== 'undefined' && typeof window.global === 'undefined') {
    // eslint-disable-next-line no-undef
    window.global = window;
}

import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'


import * as ElementPlusIconsVue from '@element-plus/icons-vue'

const app = createApp(App)


app.use(ElementPlus)


Object.entries(ElementPlusIconsVue).forEach(([name, comp]) => {
    app.component(name, comp)
})

app.use(router)
app.mount('#app')